package com.group.eams.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.group.eams.pojo.dto.AssetBorrowQueryDto;
import com.group.eams.pojo.dto.FixedAssetDetailQueryDto;
import com.group.eams.pojo.entity.AssetBorrow;
import com.group.eams.pojo.entity.AssetOutStorage;
import com.group.eams.pojo.vo.AssetBorrowListVo;
import com.group.eams.pojo.vo.FixedAssetDetailListVo;
import com.group.eams.pojo.vo.FixedAssetListVo;
import org.apache.ibatis.annotations.Param;

/**
* @author 恩哲欣
* @description 针对表【asset_borrow(资产借用表)】的数据库操作Mapper
* @createDate 2024-10-29 16:09:34
* @Entity com.group.eams.pojo.entity.AssetBorrow
*/
public interface AssetBorrowMapper extends BaseMapper<AssetBorrow> {
    Page<AssetBorrowListVo> findAssetBorrowList(Page<AssetBorrowListVo> page, @Param("assetBorrowQueryDto") AssetBorrowQueryDto assetBorrowQueryDto);
    //查询借用资产详情
    Page<FixedAssetDetailListVo> findByQueryDto(Page<FixedAssetDetailListVo> page, @Param("fixedAssetDetailQueryDto") FixedAssetDetailQueryDto fixedAssetDetailQueryDto);

    //根据单号查询借用资产
    AssetBorrow findByApplicationNum(@Param("applicationNum") String applicationNum);

    //根据单号进行删除
    int deleteByApplicationNum(@Param("applicationNum") String applicationNum);
}
